package com.gl.portal.system.entity;

import java.util.Date;

import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

import com.gl.framework.web.domain.IdEntity;

/**
 * 角色表实体
 */
@Entity
@Table(name = "sys_role")
public class SysRole extends IdEntity {

    /**
     * 角色名称
     */
    private String roleName;

    /**
     * 角色权限
     */
    private String roleKey;

    /**
     * 显示排序
     */
    private Integer sortNum;

    /**
     * 备注
     */
    private String remark;


    /**
     * 创建人
     */
    private Long createUserId;
    /**
     * 创建时间
     */
    @Column(name = "create_time")
    private Date createTime;

    /**
     * 更新人
     */
    private Long updateUserId;

    /**
     * 更新时间
     */
    private Date updateTime;


    /**
     * 角色状态（0正常 1停用）
     */
    @Basic
    @Column(name = "status", columnDefinition = "smallint")
    private Integer status;

    /**
     * 删除标志（0正常 2删除）
     */
    @Basic
    @Column(name = "is_deleted", columnDefinition = "smallint")
    private Integer isDeleted;


    public String getRoleName() {
        return roleName;
    }

    public void setRoleName(String roleName) {
        this.roleName = roleName;
    }

    public String getRoleKey() {
        return roleKey;
    }

    public void setRoleKey(String roleKey) {
        this.roleKey = roleKey;
    }

    public Integer getSortNum() {
        return sortNum;
    }

    public void setSortNum(Integer sortNum) {
        this.sortNum = sortNum;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public Long getCreateUserId() {
        return createUserId;
    }

    public void setCreateUserId(Long createUserId) {
        this.createUserId = createUserId;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Long getUpdateUserId() {
        return updateUserId;
    }

    public void setUpdateUserId(Long updateUserId) {
        this.updateUserId = updateUserId;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public Integer getIsDeleted() {
        return isDeleted;
    }

    public void setIsDeleted(Integer isDeleted) {
        this.isDeleted = isDeleted;
    }

    @Override
    public String toString() {
        return "SysRole [id=" + id + ", roleName=" + roleName + ", roleKey=" + roleKey + ", sortNum=" + sortNum
                + ", status=" + status + ", isDeleted=" + isDeleted + ", createUserId=" + createUserId + ", createTime=" + createTime
                + ", updateUserId=" + updateUserId + ", updateTime=" + updateTime + ", remark=" + remark + "]";
    }

}
